package com.bsoft.gol.editor.editor;

import javax.persistence.*;
import java.math.BigDecimal;
import java.util.Date;

/**
 * 表单题目表
 */
@Entity(name="EditorQuestionnaireTitle")
@Table(name = "editor_questionnaire_title", catalog = "")
public class EditorQuestionnaireTitle {
    /**
     * <pre>
     * 题目id
     * 表字段 : editor_questionnaire_title.title_id
     * </pre>
     */
    private String titleId;

    /**
     * <pre>
     * 表单id
     * 表字段 : editor_questionnaire_title.questionnaire_id
     * </pre>
     */
    private String questionnaireId;

    /**
     * <pre>
     * 控件类型
     * 表字段 : editor_questionnaire_title.widget_type
     * </pre>
     */
    private Byte widgetType;

    /**
     * <pre>
     * 题目名称
     * 表字段 : editor_questionnaire_title.title_name
     * </pre>
     */
    private String titleName;

    /**
     * <pre>
     * 题号
     * 表字段 : editor_questionnaire_title.title_num
     * </pre>
     */
    private Integer titleNum;

    private Integer orderNum;

    /**
     * <pre>
     * 是否必填
     * 表字段 : editor_questionnaire_title.write_flag
     * </pre>
     */
    private Byte writeFlag = 2;

    /**
     * <pre>
     * 关联项目代码
     * 表字段 : editor_questionnaire_title.relate_code_id
     * </pre>
     */
    private String relateCodeId;

    /**
     * <pre>
     * 是否有跳题逻辑
     * 表字段 : editor_questionnaire_title.skip_flag
     * </pre>
     */
    private Byte skipFlag;

    /**
     * <pre>
     * 是否有显示逻辑
     * 表字段 : editor_questionnaire_title.display_logic_flag
     * </pre>
     */
    private Byte displayLogicFlag;

    /**
     * <pre>
     * 是否显示
     * 表字段 : editor_questionnaire_title.display_flag
     * </pre>
     */
    private Byte displayFlag;

    /**
     * <pre>
     * 选择布局
     * 表字段 : editor_questionnaire_title.layout
     * </pre>
     */
    private Byte layout;

    /**
     * <pre>
     * 可选范围最多
     * 表字段 : editor_questionnaire_title.max_options
     * </pre>
     */
    private Byte maxOptions;

    /**
     * <pre>
     * 可选范围最少
     * 表字段 : editor_questionnaire_title.min_options
     * </pre>
     */
    private Byte minOptions;

    /**
     * <pre>
     * 关联字典
     * 表字段 : editor_questionnaire_title.dict_id
     * </pre>
     */
    private String dictId;

    /**
     * <pre>
     * 字典选择方式
     * 表字段 : editor_questionnaire_title.dict_select_method
     * </pre>
     */
    private Byte dictSelectMethod;

    /**
     * <pre>
     * 选项修改
     * 表字段 : editor_questionnaire_title.option_modify_flag
     * </pre>
     */
    private Byte optionModifyFlag;

    /**
     * <pre>
     * 答案字段类型
     * 表字段 : editor_questionnaire_title.answer_type
     * </pre>
     */
    private Byte answerType;

    /**
     * <pre>
     * 数据上限
     * 表字段 : editor_questionnaire_title.data_up_limit
     * </pre>
     */
    private String dataUpLimit;

    /**
     * <pre>
     * 数据下限
     * 表字段 : editor_questionnaire_title.data_down_limit
     * </pre>
     */
    private String dataDownLimit;

    /**
     * <pre>
     * 填写提示
     * 表字段 : editor_questionnaire_title.write_tips
     * </pre>
     */
    private String writeTips;

    /**
     * <pre>
     * 填空外观类型
     * 表字段 : editor_questionnaire_title.write_outward_type
     * </pre>
     */
    private Byte writeOutwardType;

    /**
     * <pre>
     * 填空宽度
     * 表字段 : editor_questionnaire_title.write_width
     * </pre>
     */
    private String writeWidth;

    /**
     * <pre>
     * 填空高度
     * 表字段 : editor_questionnaire_title.write_height
     * </pre>
     */
    private String writeHeight;

    /**
     * <pre>
     * 排列方式
     * 表字段 : editor_questionnaire_title.rank_type
     * </pre>
     */
    private Byte rankType;

    /**
     * <pre>
     * 上传文件类型
     * 表字段 : editor_questionnaire_title.upload_file_type
     * </pre>
     */
    private String uploadFileType;

    /**
     * <pre>
     * 文件大小限制
     * 表字段 : editor_questionnaire_title.upload_filesize_limit
     * </pre>
     */
    private String uploadFilesizeLimit;

    /**
     * <pre>
     * 上传数量上限
     * 表字段 : editor_questionnaire_title.upload_num_limit
     * </pre>
     */
    private Byte uploadNumLimit;

    /**
     * <pre>
     * 矩阵行列数
     * 表字段 : editor_questionnaire_title.matrix_ranks_num
     * </pre>
     */
    private String matrixRanksNum;

    /**
     * <pre>
     * 矩阵序列号标识
     * 表字段 : editor_questionnaire_title.matrix_num_flag
     * </pre>
     */
    private Byte matrixNumFlag;

    /**
     * <pre>
     * 矩阵列标题
     * 表字段 : editor_questionnaire_title.matrix_col_title
     * </pre>
     */
    private String matrixColTitle;

    /**
     * <pre>
     * 矩阵行标题
     * 表字段 : editor_questionnaire_title.matrix_row_title
     * </pre>
     */
    private String matrixRowTitle;

    /**
     * <pre>
     * 创建人
     * 表字段 : editor_questionnaire_title.create_id
     * </pre>
     */
    private Integer createId;

    /**
     * <pre>
     * 创建时间
     * 表字段 : editor_questionnaire_title.create_time
     * </pre>
     */
    private Date createTime;

    /**
     * <pre>
     * 选项内容
     * 表字段 : editor_questionnaire_title.title_content
     * </pre>
     */
    private String titleContent;

    private String returnObject;

    /**
     * <pre>
     * 是否返回
     * 表字段 : editor_questionnaire_title.title_return
     * </pre>
     */
    private Byte titleReturn;

    //拖动前题号
    private Integer preTitleNum;

    //拖动后题号
    private Integer afterTitleNum;

    //拖动前排序号
    private Integer preOrderNum;

    //拖动后排序号
    private Integer afterOrderNum;



    private BigDecimal optionGrade;

    private String code;

    private String region;


    /**
     * 权限用户
     */
    private String permissionUser;

    /**
     * 可选数量上限
     */
    private Integer optionUpperLimit;

    /**
     * 数据格式1文本、2数字、3手机、4邮箱、5日期、6日期+时间
     */
    private Integer dataFormat;

    /**
     * 提示文字
     */
    private String promptText;

    /**
     * 默认值
     */
    private String defaultValue;

    /**
     * 展示字段项备注1是、2否
     */
    private Integer showDic;

    /**
     * 是否允许新增行 1是、2否
     */
    private Integer canAddRow;
    /**
     * 允许0星 默认值 '1'
     */
    private String allowEmpty = "1";
    /**
     *允许半星 默认值 ‘1
     */
    private String allowHalf = "1";
    /**
     *:总星个数 默认值 '5'
     */
    private String startTotal = "5";
    /**
     *单星分数 默认值 ""
     */
    private String startMark = "";


    @Id
    @Column(name = "title_id")
    public String getTitleId() {
        return titleId;
    }

    public void setTitleId(String titleId) {
        this.titleId = titleId;
    }
    @Basic
    @Column(name = "questionnaire_id")
    public String getQuestionnaireId() {
        return questionnaireId;
    }

    public void setQuestionnaireId(String questionnaireId) {
        this.questionnaireId = questionnaireId;
    }
    @Basic
    @Column(name = "widget_type")
    public Byte getWidgetType() {
        return widgetType;
    }

    public void setWidgetType(Byte widgetType) {
        this.widgetType = widgetType;
    }
    @Basic
    @Column(name = "title_name")
    public String getTitleName() {
        return titleName;
    }

    public void setTitleName(String titleName) {
        this.titleName = titleName;
    }
    @Basic
    @Column(name = "title_num")
    public Integer getTitleNum() {
        return titleNum;
    }

    public void setTitleNum(Integer titleNum) {
        this.titleNum = titleNum;
    }

    @Basic
    @Column(name = "order_num")
    public Integer getOrderNum() {
        return orderNum;
    }

    public void setOrderNum(Integer orderNum) {
        this.orderNum = orderNum;
    }
    @Basic
    @Column(name = "write_flag")
    public Byte getWriteFlag() {
        return writeFlag;
    }

    public void setWriteFlag(Byte writeFlag) {
        this.writeFlag = writeFlag;
    }

    @Basic
    @Column(name = "relate_code_id")
    public String getRelateCodeId() {
        return relateCodeId;
    }

    public void setRelateCodeId(String relateCodeId) {
        this.relateCodeId = relateCodeId;
    }
    @Basic
    @Column(name = "skip_flag")
    public Byte getSkipFlag() {
        return skipFlag;
    }

    public void setSkipFlag(Byte skipFlag) {
        this.skipFlag = skipFlag;
    }
    @Basic
    @Column(name = "display_logic_flag")
    public Byte getDisplayLogicFlag() {
        return displayLogicFlag;
    }

    public void setDisplayLogicFlag(Byte displayLogicFlag) {
        this.displayLogicFlag = displayLogicFlag;
    }
    @Basic
    @Column(name = "display_flag")
    public Byte getDisplayFlag() {
        return displayFlag;
    }

    public void setDisplayFlag(Byte displayFlag) {
        this.displayFlag = displayFlag;
    }
    @Basic
    @Column(name = "layout")
    public Byte getLayout() {
        return layout;
    }

    public void setLayout(Byte layout) {
        this.layout = layout;
    }
    @Basic
    @Column(name = "max_options")
    public Byte getMaxOptions() {
        return maxOptions;
    }

    public void setMaxOptions(Byte maxOptions) {
        this.maxOptions = maxOptions;
    }

    @Basic
    @Column(name = "min_options")
    public Byte getMinOptions() {
        return minOptions;
    }

    public void setMinOptions(Byte minOptions) {
        this.minOptions = minOptions;
    }
    @Basic
    @Column(name = "dict_id")
    public String getDictId() {
        return dictId;
    }

    public void setDictId(String dictId) {
        this.dictId = dictId;
    }
    @Basic
    @Column(name = "dict_select_method")
    public Byte getDictSelectMethod() {
        return dictSelectMethod;
    }

    public void setDictSelectMethod(Byte dictSelectMethod) {
        this.dictSelectMethod = dictSelectMethod;
    }

    @Basic
    @Column(name = "option_modify_flag")
    public Byte getOptionModifyFlag() {
        return optionModifyFlag;
    }

    public void setOptionModifyFlag(Byte optionModifyFlag) {
        this.optionModifyFlag = optionModifyFlag;
    }
    @Basic
    @Column(name = "answer_type")
    public Byte getAnswerType() {
        return answerType;
    }

    public void setAnswerType(Byte answerType) {
        this.answerType = answerType;
    }
    @Basic
    @Column(name = "data_up_limit")
    public String getDataUpLimit() {
        return dataUpLimit;
    }

    public void setDataUpLimit(String dataUpLimit) {
        this.dataUpLimit = dataUpLimit;
    }

    @Basic
    @Column(name = "data_down_limit")
    public String getDataDownLimit() {
        return dataDownLimit;
    }

    public void setDataDownLimit(String dataDownLimit) {
        this.dataDownLimit = dataDownLimit;
    }
    @Basic
    @Column(name = "write_tips")
    public String getWriteTips() {
        return writeTips;
    }

    public void setWriteTips(String writeTips) {
        this.writeTips = writeTips;
    }
    @Basic
    @Column(name = "write_outward_type")
    public Byte getWriteOutwardType() {
        return writeOutwardType;
    }

    public void setWriteOutwardType(Byte writeOutwardType) {
        this.writeOutwardType = writeOutwardType;
    }
    @Basic
    @Column(name = "write_width")
    public String getWriteWidth() {
        return writeWidth;
    }

    public void setWriteWidth(String writeWidth) {
        this.writeWidth = writeWidth;
    }
    @Basic
    @Column(name = "write_height")
    public String getWriteHeight() {
        return writeHeight;
    }

    public void setWriteHeight(String writeHeight) {
        this.writeHeight = writeHeight;
    }
    @Basic
    @Column(name = "rank_type")
    public Byte getRankType() {
        return rankType;
    }

    public void setRankType(Byte rankType) {
        this.rankType = rankType;
    }

    @Basic
    @Column(name = "upload_file_type")
    public String getUploadFileType() {
        return uploadFileType;
    }

    public void setUploadFileType(String uploadFileType) {
        this.uploadFileType = uploadFileType;
    }
    @Basic
    @Column(name = "upload_filesize_limit")
    public String getUploadFilesizeLimit() {
        return uploadFilesizeLimit;
    }

    public void setUploadFilesizeLimit(String uploadFilesizeLimit) {
        this.uploadFilesizeLimit = uploadFilesizeLimit;
    }
    @Basic
    @Column(name = "upload_num_limit")
    public Byte getUploadNumLimit() {
        return uploadNumLimit;
    }

    public void setUploadNumLimit(Byte uploadNumLimit) {
        this.uploadNumLimit = uploadNumLimit;
    }
    @Basic
    @Column(name = "matrix_ranks_num")
    public String getMatrixRanksNum() {
        return matrixRanksNum;
    }

    public void setMatrixRanksNum(String matrixRanksNum) {
        this.matrixRanksNum = matrixRanksNum;
    }
    @Basic
    @Column(name = "matrix_num_flag")
    public Byte getMatrixNumFlag() {
        return matrixNumFlag;
    }

    public void setMatrixNumFlag(Byte matrixNumFlag) {
        this.matrixNumFlag = matrixNumFlag;
    }
    @Basic
    @Column(name = "matrix_col_title")
    public String getMatrixColTitle() {
        return matrixColTitle;
    }

    public void setMatrixColTitle(String matrixColTitle) {
        this.matrixColTitle = matrixColTitle;
    }
    @Basic
    @Column(name = "matrix_row_title")
    public String getMatrixRowTitle() {
        return matrixRowTitle;
    }

    public void setMatrixRowTitle(String matrixRowTitle) {
        this.matrixRowTitle = matrixRowTitle;
    }
    @Basic
    @Column(name = "create_id")
    public Integer getCreateId() {
        return createId;
    }

    public void setCreateId(Integer createId) {
        this.createId = createId;
    }

    @Basic
    @Column(name = "create_time")
    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }
    @Basic
    @Column(name = "title_content")
    public String getTitleContent() {
        return titleContent;
    }

    public void setTitleContent(String titleContent) {
        this.titleContent = titleContent;
    }

    @Basic
    @Column(name = "option_grade")
    public BigDecimal getOptionGrade() {
        return optionGrade;
    }

    public void setOptionGrade(BigDecimal optionGrade) {
        this.optionGrade = optionGrade;
    }

    private String optionIds;

    @Transient
    public String getOptionIds() {
        return optionIds;
    }

    public void setOptionIds(String optionIds) {
        this.optionIds = optionIds;
    }


    @Basic
    @Column(name = "title_return")
    public Byte getTitleReturn() {
        return titleReturn;
    }

    public void setTitleReturn(Byte titleReturn) {
        this.titleReturn = titleReturn;
    }

    @Basic
    @Column(name = "return_object")
    public String getReturnObject() {
        return returnObject;
    }

    public void setReturnObject(String returnObject) {
        this.returnObject = returnObject;
    }


    @Basic
    @Column(name = "code")
    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
    }


    @Basic
    @Column(name = "region")
    public String getRegion() {
        return region;
    }

    public void setRegion(String region) {
        this.region = region;
    }

    @Transient
    public Integer getPreTitleNum() {
        return preTitleNum;
    }

    public void setPreTitleNum(Integer preTitleNum) {
        this.preTitleNum = preTitleNum;
    }

    @Transient
    public Integer getAfterTitleNum() {
        return afterTitleNum;
    }

    public void setAfterTitleNum(Integer afterTitleNum) {
        this.afterTitleNum = afterTitleNum;
    }

    @Transient
    public Integer getPreOrderNum() {
        return preOrderNum;
    }

    public void setPreOrderNum(Integer preOrderNum) {
        this.preOrderNum = preOrderNum;
    }

    @Transient
    public Integer getAfterOrderNum() {
        return afterOrderNum;
    }

    public void setAfterOrderNum(Integer afterOrderNum) {
        this.afterOrderNum = afterOrderNum;
    }

    @Basic
    @Column(name = "permission_user")
    public String getPermissionUser() {
        return permissionUser;
    }

    public void setPermissionUser(String permissionUser) {
        this.permissionUser = permissionUser;
    }

    @Basic
    @Column(name = "option_upper_limit")
    public Integer getOptionUpperLimit() {
        return optionUpperLimit;
    }

    public void setOptionUpperLimit(Integer optionUpperLimit) {
        this.optionUpperLimit = optionUpperLimit;
    }

    @Basic
    @Column(name = "data_format")
    public Integer getDataFormat() {
        return dataFormat;
    }

    public void setDataFormat(Integer dataFormat) {
        this.dataFormat = dataFormat;
    }

    @Basic
    @Column(name = "prompt_text")
    public String getPromptText() {
        return promptText;
    }

    public void setPromptText(String promptText) {
        this.promptText = promptText;
    }

    @Basic
    @Column(name = "default_value")
    public String getDefaultValue() {
        return defaultValue;
    }

    public void setDefaultValue(String defaultValue) {
        this.defaultValue = defaultValue;
    }

    @Basic
    @Column(name = "show_dic")
    public Integer getShowDic() {
        return showDic;
    }

    public void setShowDic(Integer showDic) {
        this.showDic = showDic;
    }

    @Basic
    @Column(name = "can_add_row")
    public Integer getCanAddRow() {
        return canAddRow;
    }

    public void setCanAddRow(Integer canAddRow) {
        this.canAddRow = canAddRow;
    }

    @Basic
    @Column(name = "allow_empty")
    public String getAllowEmpty() {
        return allowEmpty;
    }

    public void setAllowEmpty(String allowEmpty) {
        this.allowEmpty = allowEmpty;
    }

    @Basic
    @Column(name = "allow_half")
    public String getAllowHalf() {
        return allowHalf;
    }

    public void setAllowHalf(String allowHalf) {
        this.allowHalf = allowHalf;
    }

    @Basic
    @Column(name = "start_total")
    public String getStartTotal() {
        return startTotal;
    }

    public void setStartTotal(String startTotal) {
        this.startTotal = startTotal;
    }

    @Basic
    @Column(name = "start_mark")
    public String getStartMark() {
        return startMark;
    }

    public void setStartMark(String startMark) {
        this.startMark = startMark;
    }
}